public class HRDepartment extends Department{
    @Override
    public void visit(FulltimeEmployee employee) {
        employee.setWorkTime(employee.getWorkTime()+5);
        System.out.println(employee.getName()+"的工作时长+5，变为"+employee.getWorkTime());
        System.out.println("--------------------------------------------------------------");
    }

    @Override
    public void visit(ParttimeEmployee employee) {
        employee.setWorkTime(employee.getWorkTime()+5);
        System.out.println(employee.getName()+"的工作时长+5，变为"+employee.getWorkTime());
        System.out.println("--------------------------------------------------------------");
    }
}
